package com.dkm.ec.product.repository.impl;

import javax.annotation.Resource;

import org.springframework.stereotype.Repository;

import com.dkm.base.core.helper.SpringHelper;
import com.dkm.base.db.persistence.dao.IQueryDao;
import com.dkm.biz.repository.AbstractRepository;
import com.dkm.ec.product.domain.ProdRel;
import com.dkm.ec.product.persistence.dao.ProdRelQueryDao;
import com.dkm.ec.product.persistence.entity.ProdRelPo;
import com.dkm.ec.product.repository.ProdRelRepository;

/**
 * 对象功能:产品关联 Repository接口的实现类
 * 开发公司:SKG.COM
 * 开发人员:Yuki
 * 创建时间:2014-12-25 09:39:25
 */
@Repository
public class ProdRelRepositoryImpl extends AbstractRepository<String, ProdRelPo,ProdRel> implements ProdRelRepository{
	  
	@Resource
	private  ProdRelQueryDao prodRelQueryDao;

	public ProdRel newInstance() {
		ProdRelPo po = new ProdRelPo();
		ProdRel prodRel = SpringHelper.getBean(ProdRel.class);
		prodRel.setData(po);
		return prodRel;
	}

	public ProdRel newInstance(ProdRelPo po) {
		ProdRel prodRel = SpringHelper.getBean(ProdRel.class);
		prodRel.setData(po);
		return prodRel;
	} 
	
	@Override
	protected IQueryDao<String, ProdRelPo> getQueryDao() {
		return prodRelQueryDao;
	}
	
}
